package bist.believeinstep.logic;

import java.util.List;

import bist.believeinstep.domain.SubMenu;
import bist.believeinstep.impl.SubmenuTemplate;
import bist.believeinstep.util.Util;

public class SubmenuService {
	private SubmenuTemplate submenuTemplate;
	
	public SubmenuService(){
		submenuTemplate = (SubmenuTemplate)Util.getConnection("submenuTemplate");
	}
	public void create(SubMenu subMenu){
		submenuTemplate.create(subMenu);
	}
	public void update(SubMenu subMenu){
		submenuTemplate.update(subMenu);
	}
	public void delete(Integer id){
		submenuTemplate.delete(id);
	}
	public SubMenu getSubMenu(Integer id){
		return submenuTemplate.getSubMenu(id);
	}
	public SubMenu getSubMenu(String name){
		return submenuTemplate.getSubMenu(name);
	}
	public List<SubMenu> list(){
		return submenuTemplate.list();
	}
}
